package cn.itsource.fegin.client.fallback;

import cn.itsource.domain.User;
import cn.itsource.fegin.client.UserFeignClient;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Component;

/**
 * 这里是user的兜底类
 */
@Component
public class UserFeignClientFallback implements UserFeignClient {



    //日志打印器
    private Logger log = LoggerFactory.getLogger(UserFeignClientFallback.class);

    @Override
    public User getUserById(Long id) {
        log.info("用户服务不可用");
        return null;
    }
}
